home *** CD-ROM | disk | FTP | other *** search
/ Linux Cubed Series 7: Sunsite / Linux Cubed Series 7 - Sunsite Vol 1.iso / system / news / inn1.000 / inn1.4sec-linux-src.tar / inn / frontends / rn.pch < prev    next >
Text File  |  1991-12-20  |  5KB  |  200 lines

  1. $Revision: 1.2 $
  2.  
  3. The following patch changes Configure and Makefile.SH in rn (version 4.4
  4. patchlevel 2) to build with the INN libraries.  Apply this patch to your rn
  5. sources, run Configure, and build.
  6.  
  7.  
  8. Index: Configure
  9. Prereq: 4.4.2.1
  10. diff -c Configure.orig Configure
  11. *** Configure.orig    Wed Dec 11 09:27:38 1991
  12. --- Configure    Wed Dec 11 18:32:59 1991
  13. ***************
  14. *** 1959,1965 ****
  15. --- 1959,2015 ----
  16.       isrrn=define
  17.       spool=/tmp
  18.       $echo "net.foobar 00001 00001 y" > .falseactive
  19. +     $echo " "
  20. +     case "$isinn" in
  21. +     define) dflt="y" ;;
  22. +     *) dflt="n" ;;
  23. +     esac
  24. +     isinn=''
  25. +     $echo $n "Do you want to use the InterNetNews library? [$dflt] $c"
  26. +     . myread
  27. +     case "$ans" in
  28. +     '') ans="$dflt";;
  29. +     esac
  30. +     case "$ans" in
  31. +     y*)
  32. +     serverfile='INN config file'
  33. +     isinn='define'
  34. +     ans='blurfl/dyick'
  35. +     while $test ! -r "$ans"; do
  36. +         dflt='../inn/include'
  37. +         $echo $n "Enter the directory with myserver.h: [$dflt] $c"
  38. +         . myread
  39. +         case "$ans" in
  40. +         '') ans="$dflt";;
  41. +         esac
  42. +         ans=`filexp "$ans"`
  43. +         if $test ! -r $ans/myserver.h ; then
  44. +         $echo "Can't find $ans/myserver.h!"
  45. +         ans='blurfl/dyick'
  46. +         fi
  47. +     done
  48. +     cp $ans/myserver.h myserver.h
  49. +     ans='blurfl/dyick'
  50. +     while $test ! -r "$ans"; do
  51. +         dflt='../inn'
  52. +         $echo $n "Enter the directory with libinn.a: [$dflt] $c"
  53. +         . myread
  54. +         case "$ans" in
  55. +         '') ans="$dflt";;
  56. +         esac
  57. +         ans=`filexp "$ans"`
  58. +         if $test ! -r $ans/libinn.a ; then
  59. +         $echo "Can't find $ans/libinn.a!"
  60. +         ans='blurfl/dyick'
  61. +         fi
  62. +     done
  63. +     innlib=$ans/libinn.a
  64. +     ;;
  65.   
  66. +     n*)
  67. +     innlib=''
  68. +     isinn=''
  69.       case "$serverfile" in
  70.       '')  dflt="no default" ;;
  71.       *)   dflt="$serverfile";;
  72. ***************
  73. *** 2018,2023 ****
  74. --- 2068,2075 ----
  75.       done
  76.       NNTPSRC="$ans"
  77.       esac
  78. +     ;;
  79. +     esac
  80.   
  81.   done
  82.   : hack for Unisys NET-5000 and Interactive V/386
  83. ***************
  84. *** 2585,2590 ****
  85. --- 2637,2643 ----
  86.   termlib='$termlib'
  87.   jobslib='$jobslib'
  88.   socketlib='$socketlib'
  89. + innlib='$innlib'
  90.   getcwd='$getcwd'
  91.   getwd='$getwd'
  92.   dirtype='$dirtype'
  93. ***************
  94. *** 2659,2664 ****
  95. --- 2712,2718 ----
  96.   norelay='$norelay'
  97.   rdchk='$rdchk'
  98.   isrrn='$isrrn'
  99. + isinn='$isinn'
  100.   serverfile='$serverfile'
  101.   NNTPSRC='$NNTPSRC'
  102.   CONFIG=true
  103. ***************
  104. *** 2683,2688 ****
  105. --- 2737,2748 ----
  106.   for file in $*; do
  107.       . $file
  108.   done
  109. + if $test -f myserver.h ; then
  110. + : what a pain that server.h.SH is now part of the RN release.
  111. +     rm -f server.h
  112. +     cp myserver.h server.h
  113. +     chmod +w server.h.SH
  114. + fi
  115.   
  116.   $echo " "
  117.   $echo 'Now you need to generate make dependencies by running "makedepend".'
  118.  
  119.  
  120. Index: Makefile.SH
  121. Prereq: 4.4.1.1
  122.  
  123. diff -rc Makefile.SH.orig Makefile.SH
  124. *** Makefile.SH.orig    Wed Dec 11 09:29:00 1991
  125. --- Makefile.SH    Wed Dec 11 18:23:34 1991
  126. ***************
  127. *** 42,52 ****
  128.   NDIRC = $ndirc
  129.   NDIRO = $ndiro
  130.   
  131. ! libs = $ndirlib $termlib $jobslib $socketlib -lm
  132.   mlibs = $jobslib
  133.   !GROK!THIS!
  134.   $cat >>Makefile <<'!NO!SUBS!'
  135.   #NNTPnntp=getactive
  136.   public = rn newsetup newsgroups Pnews Rnmail
  137.   private = norm.saver mbox.saver makedir    filexp Pnews.header $(nntp)
  138.   manpages = rn.1 Pnews.1 Rnmail.1 newsetup.1 newsgroups.1
  139. --- 42,53 ----
  140.   NDIRC = $ndirc
  141.   NDIRO = $ndiro
  142.   
  143. ! libs = $ndirlib $termlib $jobslib $socketlib $innlib -lm
  144.   mlibs = $jobslib
  145.   !GROK!THIS!
  146.   $cat >>Makefile <<'!NO!SUBS!'
  147.   #NNTPnntp=getactive
  148. + #INNnntp=getactive
  149.   public = rn newsetup newsgroups Pnews Rnmail
  150.   private = norm.saver mbox.saver makedir    filexp Pnews.header $(nntp)
  151.   manpages = rn.1 Pnews.1 Rnmail.1 newsetup.1 newsgroups.1
  152. ***************
  153. *** 57,62 ****
  154. --- 58,64 ----
  155.   h2 = common.h final.h head.h help.h init.h intrp.h kfile.h last.h 
  156.   h3 = ng.h ngdata.h ngsrch.h ngstuff.h only.h rcln.h rcstuff.h
  157.   h4 = respond.h rn.h search.h sw.h term.h util.h uudecode.h
  158. + #INNh5 = server.h
  159.   
  160.   h = $(h1) $(h2) $(h3) $(h4)
  161.   
  162. ***************
  163. *** 103,108 ****
  164. --- 105,112 ----
  165.   
  166.   #NNTPgetactive: getactive.o clientlib.o
  167.   #NNTP    $(CC) $(LDFLAGS) getactive.o clientlib.o -o getactive $(libs)
  168. + #INNgetactive: getactive.o
  169. + #INN    $(CC) $(LDFLAGS) getactive.o -o getactive $(libs)
  170.   
  171.   #NNTPclientlib.o:
  172.   #NNTP    $(CC) -c $(CFLAGS) $(NNTPINC) $(NNTPDIR)/common/clientlib.c
  173. ***************
  174. *** 156,164 ****
  175.   $(obj):
  176.       @ echo "You haven't done a "'"make depend" yet!'; exit 1
  177.   !NO!SUBS!
  178. ! case "$isrrn" in
  179. ! define)  sed < Makefile -e '/^#NNTP/s/^#NNTP//' > Makefile.new ;;
  180. ! *) sed < Makefile -e '/^#NNTP/d' > Makefile.new ;;
  181.   esac
  182.   mv Makefile.new Makefile
  183.   $eunicefix Makefile
  184. --- 160,173 ----
  185.   $(obj):
  186.       @ echo "You haven't done a "'"make depend" yet!'; exit 1
  187.   !NO!SUBS!
  188. ! case "$isinn" in
  189. ! define) sed <Makefile -e '/^#INN/s/^#INN//' -e '/^#NNTP/d' >Makefile.new ;;
  190. ! *)
  191. !     case "$isrrn" in
  192. !     define)  sed < Makefile -e '/^#NNTP/s/^#NNTP//'-e '/^#INN/d'  > Makefile.new ;;
  193. !     *) sed < Makefile -e '/^#NNTP/d' -e '/^#INN/d' > Makefile.new ;;
  194. !     esac
  195. !     ;;
  196.   esac
  197.   mv Makefile.new Makefile
  198.   $eunicefix Makefile
  199.